//
//  DetailRightkey.m
//  __PRODUCTNAME__
//
//  Created by 曹曹 on 16/08/16
//  Copyright (c) __ORGANIZATIONNAME__. All rights reserved.
//

#import "DetailRightkey.h"
#import "DetailSongrights.h"
#import "BaseModel.h"

@implementation DetailRightkey

+ (NSDictionary *)objectClassInArray{
    return @{@"songRights" : [DetailSongrights class]};
}

- (void)setValue:(id)value forKey:(NSString *)key {
    [super setValue:value forKey:key];
    if ([key isEqualToString:@"songRights"]) {
        NSMutableArray *array = [NSMutableArray array];
        for ( NSDictionary *dictionary in value) {
            DetailSongrights *songRight = [DetailSongrights modelWithDictionary:dictionary];
            [array addObject:songRight];
        }
        _songRights = array;
    }
}

@end
